<?php
namespace app\xiaozhuang\model;

use think\Db;
use think\Model;

class Classic extends Model
{
    // 获取所有的分类
    public function classic()
    {
        $classic = Db::name('classic') -> field('id, pid, name, title, type') -> select();
        return $classic;
    }
}